package com.wsl.sale.pojo;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * 创建表
 */
@Entity
@Table(name = "person")
public class Person {
    /**
     * 客户号
     * 设置主键
     */
    @Id
    private long personid;
    /**
     * 客户姓名
     */
    @Column
    private String name;

    public long getPersonid() {
        return personid;
    }

    public void setPersonid(long personid) {
        this.personid = personid;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    @Override
    public String toString() {
        return "Person{" +
                "personid=" + personid +
                ", name='" + name + '\'' +
                '}';
    }

    public Person() {
    }

    public Person(long personid, String name) {
        this.personid = personid;
        this.name = name;
    }
}
